package com.hxd.otc.module.fiat_deal.bean;

import java.io.Serializable;

/**
 * Created by lzy on 2018/12/26 0026.
 * description ${筛选Bean}
 */
public abstract class BaseFilterBean<T extends Object> implements Serializable {
    protected T item;

    public abstract String getText();

    public BaseFilterBean(T item) {
        this.item = item;
    }

    public T getItem() {
        return item;
    }

    public void setItem(T item) {
        this.item = item;
    }

    @Override
    public String toString() {
        return "BaseFilterBean{" +
                "item=" + item +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        BaseFilterBean<?> that = (BaseFilterBean<?>) o;

        return item != null ? item.equals(that.item) : that.item == null;
    }

    @Override
    public int hashCode() {
        return item != null ? item.hashCode() : 0;
    }
}
